<extend name="public@base5"/>

<block name="main">

	<div class="wrap">
		<ul class="nav nav-tabs">
			<li class="nav-item">
				<a class="nav-link" href="{:url('tag/index')}">标签列表</a>
			</li>
			<li class="nav-item">
				<a class="nav-link active" href="{:url('tag/add')}">添加标签</a>
			</li>
		</ul>
		<form method="post" class="js-ajax-form margin-top-20" action="admin/tags">
			<input type="hidden" name="id" value="{$id|default=0}">
			<div class="row mb-3">
				<label for="input-tag_name" class="col-sm-2 col-form-label text-sm-end"><span class="form-required">*</span>标签名称</label>
				<div class="col-md-4 col-sm-4">
					<input type="text" class="form-control" id="input-tag_name" name="tag_name" value="{$tag_name|default=''}" placeholder="标签名称">
				</div>
			</div>
            <div class="row mb-3">
                    <label for="input-tag_value" class="col-sm-2 col-form-label text-sm-end"><span class="form-required">*</span>标签内容</label>
                    <div class="col-md-4 col-sm-4">
                            <input type="text" class="form-control" id="input-tag_value" name="tag_value" value="{$tag_value|default=''}" placeholder="标签内容" >
                    </div>
            </div>
            <div class="row mb-3">
                    <label for="input-tag_value" class="col-sm-2 col-form-label text-sm-end"><span class="form-required">*</span>标签类型</label>
                    <div class="col-md-4 col-sm-4">
                        <select name="tag_type" class="form-control">
                            <option value="0" >全部</option>
                            <option value="1" <if condition="$tag_type eq 1">selected</if>>数字藏品</option>
                            <option value="2" <if condition="$tag_type eq 2">selected</if>>美容院</option>
                            <option value="3" <if condition="$tag_type eq 3">selected</if>>零售区</option>
                        </select>
                    </div>
            </div>
            <div class="row mb-3">
                    <div class="offset-md-2 col-sm-10">
                            <button type="submit" class="btn btn-primary js-ajax-submit">
                                    <i class="fa fa-save fa-fw"></i> {:lang('ADD')}
                            </button>
                    </div>
            </div>
    </form>
    </div>
</block>

<block name="scripts">
	<script src="__STATIC__/js/mall.js"></script>
</block>